﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Vmago.Models
{
    public class RepositoryRole:IRole
    {
        private RoleDataContext ds;

        public RepositoryRole()
        {
            ds = new RoleDataContext();
        }
        #region IRole Members

        public string RoleName(string roleName)
        {
            var r = (from p in ds.Roles
                     where p.RoleName.Equals(roleName)
                     select p).Single();

            return r.Description.ToString();
        }

        #endregion
    }
}
